Method and apparatus for timing adjustment

ABSTRACT

A strobe signal from a memory is delayed through delay circuits of a strobe delay selection section, thus obtaining a plurality of delayed strobe signals. A strobe latch section produces check data in synchronism with each of the delayed strobe signals, and a system latch section latches, with a system clock, check data latched by the strobe latch section. Based on a comparison by an expected value comparison section and a determination by a delay determination section, the optimal strobe signal with the optimal delay is selected from among the delayed strobe signals produced in the strobe delay selection section. Then, data from the memory is delayed through delay circuits in a data delay selection section, thus obtaining a plurality of delayed data, and the optimal data with the optimal delay is selected from among the plurality of delayed data based on the comparison by the expected value comparison section and the determination by the delay determination section.

CROSS REFERENCE TO RELATED APPLICATIONS

This Non-provisional application claims priority under 35 U.S.C. §119(a)on Patent Application No. 2004-381496 filed in Japan on Dec. 28, 2004,the entire contents of which are hereby incorporated by reference.

BACKGROUND OF THE INVENTION

The present invention relates to a data timing adjustment method and adata timing adjustment apparatus for adjusting data latch timing where asemiconductor device such as a memory or an LSI outputs a strobe signaland data in synchronism with the strobe signal.

Typically, timing for reading out data from a memory, an LSI, or thelike (discussion hereinbelow will focus on cases where data is read outfrom a memory) is determined in advance when the device is designed.However, the data read timing may vary due to various factors such asthe physical location of the memory, the characteristics of the memory,a voltage drop and the ambient temperature. If the readout data islatched with predetermined fixed latch timing, a data mislatch mayoccur. Therefore, it is necessary to adjust the timing with whichreadout data is latched.

With some conventional techniques, a dip switch, or the like, isprovided to allow for manual adjustment of the readout data latch timingsuch that data output from a memory is latched properly.

This method however introduces the manual adjustment operation. In viewof this, Japanese Laid-Open Patent Publication No. 2004-185608, forexample, proposes a timing adjustment apparatus that automaticallyadjusts timing with which data read out from a memory is latched.

FIG. 13 is a block diagram showing the timing adjustment apparatusdisclosed in this publication.

Referring to FIG. 13, reference numeral 1102 denotes a check datastorage section for storing check data, which is used when adjusting thetiming with which to latch data read out from a memory 1100.

Reference numeral 1103 denotes a write control section, which receives amode selection signal. When the mode selection signal indicates a normaloperation mode, the write control section 1103 writes input data to apredetermined address of the memory 1100. When the mode selection signalindicates a latch timing adjustment mode, the write control section 1103writes data stored in the check data storage section 1102 to the memory1100. Specifically, the write control section 1103 gives a timing signals1103 a, an address s1103 b and data (input data or check data) s1103 cto the memory 1100, thereby writing the data to a predetermined addressof the memory 1100.

Reference numeral 1104 denotes a read control section, which receivesthe mode selection signal. Both in the normal operation mode and in thelatch timing adjustment mode, the read control section 1104 gives atiming signal s1104 a and an address signal s1104 b to the memory 1100,thereby reading out a strobe signal DQS and data s1100 in synchronismwith the signal DQS from the memory 1100. At the end of the latch timingadjustment mode, the read control section 1104 outputs a delaydetermination signal s1104 c to a determination section 1108 and a delaycontrol section 1109 to be described later.

Reference numeral 1105 denotes a delay selection section including aseries of delay circuits 1051, 1052 to 105 n and a selection section1105 a. The delay selection section 1105 delays the strobe signal DQSfrom the memory 1100 successively through the delay circuits 1051 to 105n to produce a plurality of delayed pulse signals with different delayamounts, and one of the outputs from the delay circuits 1051 to 105 n isselected by the selection section 1105 a.

Reference numeral 1106 denotes a latch circuit for receiving the datas1100 read out from the memory 1100 and receiving a delayed pulse signalfrom one of the delay circuits of the delay selection section 1105selected by the selection section 1105 a to latch the data s1100 readout from the memory 1100 in synchronism with the delayed pulse signal.In the normal operation mode, the data latched by the latch circuit 1106is output from an output terminal 1101.

Reference numeral 1107 denotes a comparison circuit for comparing thereadout data latched by the latch circuit 1106 with the correspondingdata stored in the check data storage section 1102 to determine if thedata match with each other.

Reference numeral 1108 denotes a determination section, which receivesthe delay determination signal from the read control section 1104 at theend of the latch timing adjustment mode. Based on a plurality ofcomparison results from the comparison circuit 1107, the determinationsection 1108 determines one of the delay circuits 1051 to 105 n withwhich the readout data from the memory 1100 is appropriately latched bythe latch circuit 1106, i.e., the determination section 1108 determinesthe delayed pulse signal with the optimal delay amount.

With the technique of the above-mentioned publication, the optimal latchtiming for latching readout data from the memory 1100 is determined,thus realizing an automatic timing adjustment.

A strobe signal output from a memory is typically a signal that is addedonly when there is data to be read out, and is not a continuous signalsuch as a clock signal. Therefore, in a case where data in synchronismwith such a strobe signal is input to, and used in, a semiconductorintegrated circuit that operates based on a system clock, the data insynchronism with the strobe signal needs to be latched with the strobesignal and eventually latched again with the system clock.

However, a strobe signal and a system clock are signals of separateorigins. Although the conventional latch timing adjustment apparatusadjusts the phase of the strobe signal so that readout data can bedesirably latched with the strobe signal, a mislatch may occur whendata, which has been latched with the strobe signal, is latched againwith the system clock if there is a displacement in the phaserelationship between the strobe signal and the system clock. Thus, theconventional apparatus may fail to perform a latch timing adjustmentwith a high precision.

SUMMARY OF THE INVENTION

It is therefore an object of the present invention to provide a latchtiming adjustment method and a latch timing adjustment apparatus,wherein in a case where a semiconductor device such as a memory or anLSI outputs a strobe signal and data in synchronism with the strobesignal, the latch timing is adjusted so that the data can be latchedwith the strobe signal and desirably latched again with a system clockwithout a mislatch.

According to the present invention, in order to achieve the object setforth above, two different phase adjustments are performed, i.e., aphase adjustment performed between an external strobe signal and asystem clock, and another phase adjustment performed between theexternal strobe signal and external data.

Specifically, a data latch timing adjustment method of the presentinvention is a data latch timing adjustment method for receiving anexternal strobe signal and external data in synchronism with theexternal strobe signal, latching the external data with the externalstrobe signal and then again latching the latched external data with asystem clock, the method including: a system latch timing adjustmentstep of producing check data in synchronism with the external strobesignal and performing a phase adjustment between the external strobesignal and the system clock so that the check data is properly latchedwith the system clock; and a strobe latch timing adjustment step ofperforming a phase adjustment between the external strobe signal and theexternal data so that the external data is properly latched with theexternal strobe signal, the external strobe signal having apredetermined phase relationship with the system clock as a result ofthe phase adjustment performed in the system latch timing adjustmentstep.

In an embodiment of the present invention, in the system latch timingadjustment step: a plurality of delayed strobe signals are produced bydelaying the external strobe signal with a plurality of delay amounts,and the check data is produced in synchronism with each delayed strobesignal; and one of the plurality of delayed strobe signals for which thecorresponding check data is properly latched with the system clock isselected as an optimal strobe signal.

In an embodiment of the present invention, in the system latch timingadjustment step: the check data is produced in synchronism with theexternal strobe signal; a plurality of delayed system clocks areproduced by delaying the system clock with a plurality of delay amounts,and the check data is latched with each of the plurality of delayedsystem clocks; and one of the plurality of delayed system clocks withwhich the check data is properly latched is selected as an optimalsystem clock.

In an embodiment of the present invention, in the strobe latch timingadjustment step: a plurality of delayed data are produced by delayingthe external data with a plurality of delay amounts; the plurality ofdelayed data are latched with the external strobe signal; and one of theplurality of delayed data properly latched is selected as optimal data.

In an embodiment of the present invention, the system latch timingadjustment step and the strobe latch timing adjustment step are eachperformed when a predetermined timing adjustment request is issued; anda time at which the predetermined timing adjustment request is issuedincludes at least one of at a system startup, at a system initializationand during a normal operation.

In an embodiment of the present invention, the external strobe signalincludes a plurality of bits; when the system latch timing adjustmentstep is requested at a system startup or at a system initialization, aplurality of delayed strobe signals are produced by delaying each bit ofthe external strobe signal with a plurality of delay amounts in thesystem latch timing adjustment step; and when the system latch timingadjustment step is requested during a normal operation, a plurality ofdelayed strobe signals are produced by delaying each of a predeterminednumber of bits of the external strobe signal with a plurality of delayamounts in the system latch timing adjustment step, the predeterminednumber of bits being less than the total number of bits of the externalstrobe signal.

In an embodiment of the present invention, the external data includes aplurality of bits; when the strobe latch timing adjustment step isrequested at a system startup or at a system initialization, a pluralityof delayed data are produced by delaying each bit of the external datawith a plurality of delay amounts in the strobe latch timing adjustmentstep; and when the strobe latch timing adjustment step is requestedduring a normal operation, a plurality of delayed data are produced bydelaying each of a predetermined number of bits of the external datawith a plurality of delay amounts in the strobe latch timing adjustmentstep, the predetermined number of bits being less than the total numberof bits of the external data.

A data latch timing adjustment apparatus of the present invention is adata latch timing adjustment apparatus for receiving an external strobesignal and external data in synchronism with the external strobe signal,latching the external data with the external strobe signal and thenagain latching the latched external data with a system clock, theapparatus including: a strobe delay selection section for delaying theexternal strobe signal with a plurality of delay amounts to produce aplurality of delayed strobe signals and selectively outputting one ofthe delayed strobe signals produced; a data delay selection section fordelaying the external data with a plurality of delay amounts to producea plurality of delayed data and selectively outputting one of thedelayed data produced; a strobe latch section for receiving the delayeddata from the data delay selection section and the delayed strobe signalselected by the strobe delay selection section to produce check data insynchronism with the delayed strobe signal and to latch the receiveddelayed data or the produced check data in synchronism with the delayedstrobe signal; a system latch section for latching, with the systemclock, the delayed data or the check data latched by the strobe latchsection; a strobe delay control section for controlling the strobe delayselection section; and a data delay control section for controlling thedata delay selection section.

In an embodiment of the present invention, the data latch timingadjustment apparatus further includes: an expected value comparisonsection for comparing the delayed data or the check data latched by thesystem latch section with a corresponding expected value to determinewhether or not the delayed data or the check data matches with theexpected value; a strobe delay determination section for receiving acomparison result from the expected value comparison section anddetermining one of the plurality of delayed strobe signals produced inthe strobe delay selection section to be an optimal strobe signal; and adata delay determination section for receiving a comparison result fromthe expected value comparison section and determining one of theplurality of delayed data produced in the data delay selection sectionto be optimal data.

Another data latch timing adjustment apparatus of the present inventionis a data latch timing adjustment apparatus for receiving an externalstrobe signal and external data in synchronism with the external strobesignal, latching the external data with the external strobe signal andthen again latching the latched external data with a system clock, theapparatus including: a clock delay selection section for delaying thesystem clock with a plurality of delay amounts to produce a plurality ofdelayed system clocks and selectively outputting one of the delayedsystem clocks produced; a strobe latch section for receiving theexternal data and the external strobe signal to produce check data insynchronism with the external strobe signal and to latch the receivedexternal data or the produced check data in synchronism with theexternal strobe signal; a system latch section for latching, with thedelayed system clock selected by the clock delay selection section, theexternal data or the check data latched by the strobe latch section; anda clock delay control section for controlling the clock delay selectionsection.

In an embodiment of the present invention, the data latch timingadjustment apparatus further includes: a data delay selection sectionfor delaying the external data with a plurality of delay amounts toproduce a plurality of delayed data and selectively outputting one ofthe delayed data produced; and a data delay control section forcontrolling the data delay selection section.

In an embodiment of the present invention, the data latch timingadjustment apparatus further includes: an expected value comparisonsection for comparing the external data or the check data latched by thesystem latch section with a corresponding expected value to determinewhether or not the external data or the check data matches with theexpected value; a clock delay determination section for receiving acomparison result from the expected value comparison section anddetermining one of the plurality of delayed system clocks produced inthe clock delay selection section to be an optimal system clock; and adata delay determination section for receiving a comparison result fromthe expected value comparison section and determining one of theplurality of delayed data produced in the data delay selection sectionto be optimal data.

In an embodiment of the present invention, the clock delay selectionsection includes: a fixed delay section for simultaneously producing aplurality of system clocks of different phases and selectivelyoutputting one of the plurality of system clocks; and a variable delaysection connected in series with the fixed delay section and including aseries of delay circuits.

In an embodiment of the present invention, either one of the strobedelay control section and the data delay control section is provided andfunctions both as the strobe delay control section and as the data delaycontrol section.

In an embodiment of the present invention, the external strobe signal isan n-bit (n is an integer greater than or equal to 2) signal; and anumber n of the strobe delay selection sections are provided.

In an embodiment of the present invention, the expected value comparisonsection is used commonly in a strobe delay control operation and in adata delay control operation; either one of the strobe delaydetermination section and the data delay determination section isprovided and functions both as the strobe delay determination sectionand as the data delay determination section; and different data can beselected as the check data in the strobe delay control operation and inthe data delay control operation.

In an embodiment of the present invention, the expected value comparisonsection is used commonly in a clock delay control operation and in adata delay control operation; either one of the clock delaydetermination section and the data delay determination section isprovided and functions both as the clock delay determination section andas the data delay determination section; and different data can beselected as the check data in the clock delay control operation and inthe data delay control operation.

In an embodiment of the present invention, any data can be input fromoutside as the check data.

As described above, according to the present invention, a first phaseadjustment is performed between the external strobe signal and thesystem clock, and a second phase adjustment is performed between theexternal strobe signal and the external data, whereby after the externaldata is latched with the external strobe signal, the latched data can belatched again with the system clock precisely without a mislatch. Forexample, in the first phase adjustment, the phase of one of the externalstrobe signal and the system clock may be adjusted while fixing thephase of the other so as to achieve an optimal phase relationshiptherebetween. Then, in the second phase adjustment, the phase of theexternal data can be adjusted with respect to the external strobesignal, which now has the optimal phase relationship with respect to thesystem clock, to achieve an optimal phase relationship therebetween.Then, the external data, which is in synchronism with the externalstrobe signal, can be properly latched with the system clock.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram showing a general configuration of a datalatch timing adjustment apparatus according to a first embodiment of thepresent invention.

FIG. 2 is a flow chart showing a data latch timing adjustment methodusing the latch timing adjustment apparatus.

FIG. 3 is a flow chart showing in detail a system latch timingadjustment step in the latch timing adjustment method.

FIG. 4 is a flow chart showing in detail a strobe latch timingadjustment step in the latch timing adjustment method.

FIG. 5 is a timing diagram of the system latch timing adjustment step.

FIG. 6 is a timing diagram of the strobe latch timing adjustment step.

FIG. 7 is a block diagram showing a general configuration of a datalatch timing adjustment apparatus according to a first variation of thefirst embodiment of the present invention.

FIG. 8 is a block diagram showing a general configuration of a datalatch timing adjustment apparatus according to a second variation of thefirst embodiment of the present invention.

FIG. 9 is a flow chart showing a data timing adjustment method using thelatch timing adjustment apparatus.

FIG. 10 is a block diagram showing a general configuration of a datalatch timing adjustment apparatus according to a second embodiment ofthe present invention.

FIG. 11 is a timing diagram of a system latch timing adjustment step inthe latch timing adjustment method.

FIG. 12 shows an internal configuration of a clock delay selectionsection provided in a data latch timing adjustment apparatus accordingto a first variation of the second embodiment of the present invention.

FIG. 13 is a block diagram showing a general configuration of aconventional data latch timing adjustment apparatus.

DETAILED DESCRIPTION OF THE INVENTION

Preferred embodiments of the present invention will now be describedwith reference to the accompanying drawings.

FIRST EMBODIMENT

FIG. 1 shows a data latch timing adjustment apparatus according to afirst embodiment of the present invention. Where a memory 100 outputs astrobe signal s100 a and data s100 b in synchronism with the strobesignal s100 a, the latch timing adjustment apparatus shown in FIG. 1adjusts the latch timing for the external data s100 b. The latch timingadjustment apparatus is a single LSI including the circuits, and thelike, other than the memory 100.

While the present embodiment is directed to a case where a latch timingadjustment is performed for the strobe signal s100 a and the data s100 bfrom the memory 100 as being the external strobe signal and the externaldata, it is understood that the present invention is also applicable toa case where a latch timing adjustment is performed for a strobe signaland data that are output from any source other than the memory 100, suchas an LSI.

In FIG. 1, reference numeral 101 denotes a write control section andreference numeral 102 denotes a read control section. These controlsections 101 and 102 receive a mode selection signal. When the modeselection signal indicates the latch timing adjustment mode, the controlsections 101 and 102 control the memory 100 to output the strobe signals100 a and the predetermined external data s100 b. These controlsections will be described in detail after the description of otherimportant circuit elements.

In FIG. 1, reference numeral 103 denotes a strobe delay selectionsection, including a series of delay circuits 1031, 1032 to 103 n and aselection section 103 a at the last stage. The strobe delay selectionsection 103 delays the strobe signal s100 a from the memory 100successively through the delay circuits 1031 to 103 n to produce aplurality of delayed strobe signals with different delay amounts, andone of the outputs from the delay circuits 1031 to 103 n is selected bythe selection section 103 a.

Reference numeral 104 denotes a data delay selection section, includinga series of delay circuits 1041, 1042 to 104 n and a selection section104 a at the last stage. The data delay selection section 104 delays thereadout data s100 b from the memory 100 successively through the delaycircuits 1041 to 104 n to produce a plurality of delayed data withdifferent delay amounts, and one of the outputs from the delay circuits1041 to 104 n is selected by the selection section 104 a.

Reference numeral 106 denotes a strobe latch section. In the systemlatch timing adjustment mode, the strobe latch section 106 successivelyreceives a delayed strobe signal from one of the delay circuits selectedby the selection section 103 a of the strobe delay selection section103, and produces check data in synchronism with each delayed strobesignal. In the system latch timing adjustment mode, a phase adjustmentbetween the strobe signal and the system clock is performed, and it istherefore required that the strobe signal and the data are completely insynchronism with each other. Thus, even if the strobe latch section 106receives delayed data from the data delay selection section 104, thestrobe latch section 106 does not use the delayed data but separatelyproduces check data. The check data is obtained by reading out data froma data storage section 105 and producing the same data as the readoutdata.

In the strobe latch timing adjustment mode, where a phase adjustmentbetween the strobe signal s100 a and the data s100 b from the memory 100is performed, the strobe latch section 106 successively receives delayeddata from one of the delay circuits selected by the selection section104 a of the data delay selection section 104, and also receives anoptimal strobe signal obtained as a result of the phase adjustment inthe system latch timing adjustment mode, i.e., a delayed strobe signalfrom one of the delay circuits selected by the selection section 103 aof the strobe delay selection section 103. The strobe latch section 106latches each delayed data that it receives with the optimal strobesignal.

The data storage section 105 stores therein check data for use in asystem latch timing adjustment and check data for use in a strobe latchtiming adjustment, and outputs appropriate check data according to theadjustment mode. Note that these check data may be changed to any datathat is input from outside via a port 105 i by a control operation usingan IIC register, for example. This allows one to change check dataaccording to the environment after the system is mounted on a circuitboard, or the like, thus enabling an optimal latch timing adjustment.

Reference numeral 107 denotes a system latch section for latching data,which has been latched by the strobe latch section 106, with a systemclock s200. In the normal operation mode, the data latched by the systemlatch section 107 is used.

Reference numeral 108 denotes an expected value comparison section,which receives data latched by the system latch section 107. Theexpected value comparison section 108 compares the received data withthe check data for system latch timing adjustment (expected value)stored in the data storage section 105 in the system latch timingadjustment mode, and compares the received data with the check data forstrobe latch timing adjustment (expected value) stored in the datastorage section 105 in the strobe latch timing adjustment mode, tooutput the comparison result indicating a match or a mismatch.

Reference numeral 109 denotes a delay determination section (the strobedelay determination section and the clock delay determination section).At the end of the system latch timing adjustment mode, the delaydetermination section 109 receives a delay determination signal from theread control section 102, and determines, based on a plurality ofcomparison results from the expected value comparison section 108, oneof the delay circuits 1031 to 103 n of the strobe delay selectionsection 103 with which the latched data from the strobe latch section106 is properly latched by the system latch section 107, i.e., anoptimal strobe signal with the optimal delay amount. At the end of thestrobe latch timing adjustment mode, the delay determination section 109receives a delay determination signal from the read control section 102,and determines, based on a plurality of comparison results from theexpected value comparison section 108, one of the delay circuits 1041 to104 n of the data delay selection section 104 with which delayed data isproperly latched by the strobe latch section 106, i.e., optimal datawith the optimal delay amount.

A specific determination method used in the delay determination section109 will now be described. If there is only one comparison resultindicating a match among the plurality of comparison results from theexpected value comparison section 108, a delayed strobe signal ordelayed data from the corresponding delay circuit is determined to beoptimal. If there are a series of comparison results indicating a match,a delayed strobe signal or delayed data from a delay circuit in themiddle of the series of delay circuits corresponding to the series ofcomparison results, i.e., a delayed strobe signal or delayed data with asetup margin and a hold margin generally equal to each other, may bedetermined to be optimal. Alternatively, a delayed strobe signal ordelayed data from one of the series of delay circuits with a largersetup margin or a larger hold margin may be determined to be optimal.Alternatively, in order to remove isolated points, the optimal delay maybe determined based on the results from a number of consecutivecomparison operations. For example, the delay determination section 109may store the comparison results from a number of (e.g., five)consecutive comparison operations, and the selection of a delay circuitmay be updated only if the same results occur a predetermined number of(e.g., three) consecutive times, or a predetermined number of (e.g.,four) non-consecutive times.

In FIG. 1, reference numeral 110 denotes a strobe delay control section.During the period of the system latch timing adjustment mode, the strobedelay control section 110 controls the selection section 103 a so as tosuccessively select the delay circuits 1031 to 103 n of the strobe delayselection section 103 starting from the first delay circuit 1031, and atthe end of the system latch timing adjustment mode, the strobe delaycontrol section 110 receives the delay determination signal from theread control section 102 to control the selection section 103 a so as toselect the optimal strobe signal being the output from one of the delaycircuits 1031 to 103 n of the strobe delay selection section 103 asdetermined by the delay determination section 109.

Reference numeral 111 denotes a data delay control section. During theperiod of the strobe latch timing adjustment mode, the data delaycontrol section 111 controls the selection section 104 a so as tosuccessively select the delay circuits 1041 to 104 n of the data delayselection section 104 starting from the first delay circuit 1041, and atthe end of the strobe latch timing adjustment mode, the data delaycontrol section 111 receives the delay determination signal from theread control section 102 to control the selection section 104 a so as toselect the optimal data being the output from one of the delay circuits1041 to 104 n of the data delay selection section 104 as determined bythe delay determination section 109.

The write control section 101 receives the mode selection signal, and ifthe mode selection signal indicates the system latch timing adjustmentmode, the write control section 101 writes predetermined data (e.g., aseries of 0's or 1's) to the memory 100. If the mode selection signalindicates the strobe latch timing adjustment mode, the write controlsection 101 writes check data for strobe latch timing adjustment storedin the data storage section 105 to the memory 100. Note that in thenormal operation mode, the write control section 101 writes input datato a predetermined address in the memory 100. Specifically, the writecontrol section 101 gives a timing signal s101 a, an address signal s101b and data s101 c to the memory 100, thereby writing predetermined datato a predetermined address of the memory 100.

If the mode selection signal indicates the system latch timingadjustment mode or the strobe latch timing adjustment mode, the readcontrol section 102 gives a timing signal s102 a and a predeterminedaddress signal s102 b to the memory 100, thereby reading out thepredetermined data s100 b in synchronism with the strobe signal s100 afrom the memory 100, and outputs a read period signal and a delaydetermination signal to the expected value comparison section 108, thedelay determination section 109 and the strobe delay control section110. Note that also in the normal operation mode, the read controlsection 102 gives the timing signal s102 a and the address signal s102 bto the memory 100, thereby reading out the data s100 b in synchronismwith the strobe signal s100 a from the memory 100.

A timing adjustment method used by the apparatus of FIG. 1 for adjustingthe timing for latching data in synchronism with a strobe signal willnow be described with reference to the drawings.

FIG. 2 is a flow chart generally showing the process of adjusting thetiming with which data in synchronism with a strobe signal is latchedwith the system clock s200. The latch timing adjustment operation usingthe latch timing adjustment apparatus of the present embodiment will nowbe described referring to the flow chart.

Referring to FIG. 2, it is first determined in step P0 whether or notthe mode selection signal is requesting a timing adjustment. If thetiming adjustment mode is requested, the process proceeds to the systemlatch timing adjustment step of step P1. Following this step, theprocess proceeds to the strobe latch timing adjustment step of step P2,after which the process proceeds to the normal operation of step P3.Thereafter, the process repeats this loop. This allows for a timingadjustment such that the data s100 b in synchronism with the strobesignal s100 a is latched with the system clock s200 while followingchanges in the surrounding circumstances. The timing adjustment may beperformed in such a manner that the system latch timing adjustment stepis performed in response to a timing adjustment request, and the strobelatch timing adjustment step is performed in response to the next timingadjustment request.

FIG. 3 is a flow chart showing the method of the system latch timingadjustment step P1. Referring to FIG. 3, in the system latch timingadjustment mode, predetermined data s101 c, the address s101 bindicating a location in the memory 100 where the data s101 c is to bestored and the write timing signal s101 a are given to the memory 100from the write control section 101, thereby writing the data s101 c to apredetermined address of the memory 100, in advance. Note that in thesystem latch timing adjustment mode, the strobe latch section 106 doesnot use readout data from the memory 100, but produces the same data ascheck data stored in the data storage section 105.

Then, the read control section 102 gives the address signal s102 bindicating the address at which data was written previously, and theread timing signal s102 a to the memory 100, thereby reading out thestrobe signal s100 a and the data s100 b in synchronism with the strobesignal s100 a from the memory 100. This operation is performedrepeatedly so as to read the strobe signal s100 a and the data s100 bfrom the memory 100 a number of times. During this period, the strobedelay control section 110 receives a control signal from the readcontrol section 102 to output a delay selection signal to the selectionsection 103 a so as to successively select delayed strobe signals fromthe delay circuits 1031 to 103 n of the strobe delay selection section103, starting from the first delay circuit 1031, so that one delayedstrobe signal is selected each time a strobe signal is read out from thememory 100 (step Pa).

As a result, the strobe latch section 106 receives the delayed strobesignal from the first delay circuit 1031 of the strobe delay selectionsection 103 and reads out check data from the data storage section 105to produce the same data as the check data in synchronism with thedelayed strobe signal. Then, in synchronism with the delayed strobesignal from the second delay circuit 1032 of the delay selection section103, the strobe latch section 106 produces the second check data.Thereafter, the strobe latch section 106 produces i^(th) check data insynchronism with the i^(th) (i=3 to m) delayed strobe signal (step Pb).

In the system latch section 107, the check data produced by the strobelatch section 106 is latched with the system clock s200 (step Pc).

The expected value comparison section 108 compares the data latched bythe system latch section 107 with the corresponding check data forsystem latch timing adjustment (expected value) from the data storagesection 105 (step Pd), thus producing a comparison result indicating amatch or a mismatch. This is repeated m times (step Pe).

At the end of the system latch timing adjustment, a delay determinationsignal is output from the read control section 102 to the delaydetermination section 109. Based on the plurality of comparison resultsfrom the expected value comparison section 108, the delay determinationsection 109 determines one of the delay circuits 1031 to 103 n of thestrobe delay selection section 103 with which data from the strobe latchsection 106 is properly latched by the system latch section 107 (stepPf). After the optimal delay circuit, i.e., the optimal timing, isselected, the strobe delay control section 110 receives a delaydetermination signal from the read control section 102 to control theselection section 103 a so as to select the output from one delaycircuit selected by the delay determination section 109 as being theoptimal strobe signal (step Pg).

FIG. 4 is a flow chart showing the method of the strobe latch timingadjustment step P2.

Referring to FIG. 4, in the strobe latch timing adjustment mode, thecheck data s101 c for strobe latch timing adjustment from the datastorage section 105, the address s101 b indicating a location in thememory 100 where the check data s101 c is to be stored and the writetiming signal s101 a are given to the memory 100 from the write controlsection 101, thereby writing the data s101 c to a predetermined addressof the memory 100, in advance.

Then, the read control section 102 gives the address signal s102 bindicating the address at which the check data was written previously,and the read timing signal s102 a to the memory 100, thereby reading outthe strobe signal s100 a and the check data s100 b in synchronism withthe strobe signal s100 a from the memory 100. This operation isperformed repeatedly so as to successively read the check data from thememory 100 a number of times. During this period, the data delay controlsection 111 receives a control signal from the read control section 102to output a delay selection signal to the selection section 104 a so asto successively select delayed data from the delay circuits 1041 to 104n of the data delay selection section 104, starting from the first delaycircuit 1041, so that one delayed data is selected each time check datais read out from the memory 100 (step Pa).

As a result, the strobe latch section 106 receives the optimal strobesignal from the strobe delay selection section 103, which has beendetermined in the system latch timing adjustment step, and the firstdelayed data from the first delay circuit 1041 of the data delayselection section 104, and latches the first delayed data in synchronismwith the optimal strobe signal. Then, the strobe latch section 106latches the delayed data from the second delay circuit 1042 of the datadelay selection section 104 in synchronism with the optimal strobesignal. Thereafter, the strobe latch section 106 latches the j^(th) (j=3to n) delayed data in synchronism with the optimal strobe signal (stepPb).

In the system latch section 107, the data latched by the strobe latchsection 106 is latched with the system clock s200 (step Pc).

The expected value comparison section 108 compares the data latched bythe system latch section 107 with the corresponding check data forstrobe latch timing adjustment (expected value) from the data storagesection 105 (step Pd), thus producing a comparison result indicating amatch or a mismatch. This is repeated n times (step Pe).

At the end of the strobe latch timing adjustment, a delay determinationsignal is output from the read control section 102 to the delaydetermination section 109. Based on the plurality of comparison resultsfrom the expected value comparison section 108, the delay determinationsection 109 determines one of the delay circuits 1041 to 104 n of thedata delay selection section 104 with which delayed data from the datadelay selection section 104 is properly latched by the strobe latchsection 106 (step Pf). After the optimal delay circuit, i.e., theoptimal data, is selected, the data delay control section 111 receives adelay determination signal from the read control section 102 to controlthe selection section 104 a so as to select the output from one delaycircuit selected by the delay determination section 109 as being theoptimal data (step Pg).

After the mode selection signal is changed to request the normaloperation mode, the optimal delayed version of the readout data s100 bfrom the memory 100 as selected by the selection section 104 a of thedata delay selection section 104 is latched by the strobe latch section106 in synchronism with the optimal strobe signal selected by theselection section 103 a of the strobe delay selection section 103, andthen latched again by the system latch section 107 with the system clocks200, so as to be used in a normal operation.

FIG. 5 is a timing diagram of the system latch timing adjustment stepP1. Referring to FIG. 5, in the system latch timing adjustment step, adelayed strobe signal s100 a′ with a delay amount dey-s is produced fromthe strobe signal s100 a read out from the memory. Then, check data CSis produced in the strobe latch section 106 in synchronism with thedelayed strobe signal s100 a′ and latched with the system clock s200,and the latched check data SD is compared with the expected value.

FIG. 6 is a timing diagram of the strobe latch timing adjustment stepP2. Referring to FIG. 6, delayed data is produced from the data s100 bread out from the memory 100. Then, the delayed data is latched by thestrobe latch section 106 in synchronism with the optimal strobe signal,which is obtained through optimization in the system latch timingadjustment step P1, and then the latched delayed data is latched withthe system clock s200. Then, the delayed data latched with the systemclock s200 is compared with the expected value.

As described above, the latch timing adjustment step is divided into thesystem latch timing adjustment step and the strobe latch timingadjustment step. In the system latch timing adjustment step, an optimalstrobe signal is obtained by the strobe delay selection section 103 suchthat the check data can properly be latched by the system latch section107 with the system clock s200, without being dependent on the timing ofreadout data from the memory 100, thereby appropriately adjusting thephase relationship between the optimal strobe signal and the systemclock s200. In the strobe latch timing adjustment step, the readout datas100 b from the memory 100 is delayed variously through the data delayselection section 104 based on the optimal strobe signal to obtain theoptimal data, thereby appropriately adjusting also the phaserelationship between the optimal data and the optimal strobe signal. Asa result, it is possible to precisely perform the adjustment of thetiming with which the data s100 b in synchronism with the strobe signals100 a from the memory 100 is latched with the system clock s200.

Moreover, in the present embodiment, the expected value comparisonsection 108 and the delay determination section 109 are used both in thestrobe delay control operation and in the system clock delay controloperation. Therefore, it is possible to suppress an increase in thecircuit scale.

First Variation of First Embodiment

A first variation of the first embodiment will now be described withreference to FIG. 7.

In this variation, a delay control section 210 is used replacing thestrobe delay control section 110 and the data delay control section 111.

Specifically, referring to FIG. 7, the delay control section 210controls the strobe delay selection section 103 when the mode selectionsignal indicates the system latch timing adjustment mode, and controlsthe data delay selection section 104 when the mode selection signalindicates the strobe latch timing adjustment mode.

Therefore, in this variation, the delay control section 210 is usedcommonly in the strobe delay control operation and in the data delaycontrol operation, whereby it is possible to realize a high-precisiontiming adjustment while suppressing an increase in the circuit scale.

Second Variation of First Embodiment

A second variation of the first embodiment will now be described withreference to FIG. 8.

This variation is directed to a case where a strobe signal s100 a″ fromthe memory 100 has m bits (m is an integer greater than or equal to 2),and readout data s100 b″ from the memory 100 has n bits (n is an integergreater than or equal to 2).

In FIG. 8, the memory 100 outputs the m-bit strobe signal s100 a″ andthe n-bit readout data s100 b″. For example, the strobe signal s100 a″may have 4 bits, and the readout data s100 b″ may have 32 bits, wherein1 bit of the strobe signal corresponds to 8 bits of the readout data.Accordingly, the apparatus includes a number m of strobe delay selectionsections 303 for producing a delayed strobe signal for each of the mbits. Similarly, the apparatus includes a number n of data delayselection sections 304 for producing delayed data for each of the nbits.

The apparatus includes a number n of strobe latch sections 306 forlatching the delayed data of the corresponding bits produced by the ndata delay selection sections 304 with the delayed strobe signals of thecorresponding bits produced by the m strobe delay selection sections303, and for producing check data of the corresponding bits insynchronism with the delayed strobe signals selected by the selectionsections 103 a, . . . , of the m strobe delay selection sections 303A to303M.

A system latch section 307 latches data from the n bits of strobe latchsections 306A to 306N with the system clock s200.

In the system latch timing adjustment mode, an expected value comparisonsection 308 successively selects representative m bits of the n-bit datalatched by the system latch section 307 on a bit-by-bit basis to comparethe selected bit of the latched data with check data for system latchtiming adjustment stored in the data storage section 105, outputting acomparison result indicating a match or a mismatch. In the strobe latchtiming adjustment, the expected value comparison section 308successively selects n bits of data latched by the system latch section307 to compare the selected bit of the latched data with check data forstrobe latch timing adjustment stored in the data storage section 105,outputting a comparison result indicating a match or a mismatch.

A delay determination section 309 determines the optimal data and theoptimal strobe signal, as in the first embodiment.

During the period of the system latch timing adjustment mode, a delaycontrol section 310 controls a selection section 303 a so as tosuccessively select a plurality of delay circuits 3031 to 303 n in astrobe delay selection section 303 of the bit for which the adjustmentis being performed, starting from the first delay circuit 3031. At theend of the system latch timing adjustment mode, the delay controlsection 310 receives the delay determination signal from the readcontrol section 102 to control the selection section 303 a so as toselect the output from a delay circuit selected by the delaydetermination section 309, i.e., the optimal strobe signal. During theperiod of the strobe latch timing adjustment mode, the delay controlsection 310 controls a selection section 304 a so as to successivelyselect a plurality of delay circuits 3041 to 304 n in a data delayselection section 304 of the bit for which the adjustment is beingperformed, starting from the first delay circuit 3041. At the end of thestrobe latch timing adjustment mode, the delay control section 310receives the delay determination signal from the read control section102 to control the selection section 304 a so as to select the outputfrom a delay circuit selected by the delay determination section 309,i.e., the optimal data.

Therefore, according to this variation, where the strobe signal s100 a″from the memory 100 has 4 bits (m=4) and the readout data s100 b″ has 32bits (n=32), for example, in the system latch timing adjustment step,representative 4 bits of check data produced from the 4-bit delayedstrobe signal are latched with the system clock s200, and aresuccessively subjected to the comparison with an expected value, thedelay determination operation and the strobe delay control operation ona bit-by-bit basis and, in the following strobe latch timing adjustmentstep, the 32 bits of the readout data are latched by 8 bits with thecorresponding optimized delayed strobe signal, and are successivelysubjected to the comparison with an expected value, the delaydetermination and the strobe delay control operation on a bit-by-bitbasis.

Note that if a plurality of expected value comparison sections 308 areprovided, a plurality of bits may be parallelly subjected to thecomparison with an expected value and the subsequent operations.

FIG. 9 is a flow chart showing the latch timing adjustment method in acase where it is not possible to subject all bits at once to a timingadjustment operation due to a limitation on the data transfer rate ofthe memory, or the like.

In such a case, the system latch timing adjustment and the strobe latchtiming adjustment are performed consecutively for all bits in responseto a single timing adjustment request only when the normal operationwill not be affected, e.g., at the system startup or at the systeminitialization (steps S1 to S4). Thereafter, during the normaloperation, the latch timing adjustment operation is performed asfollows.

In response to a timing adjustment request, the system latch timingadjustment step (steps S5 to S9) is performed only for such a numberbits that the normal operation will not be affected, whereby the systemlatch timing adjustment step for all bits of the strobe signal iscompleted through a plurality of timing adjustment requests (iterationsof steps S5 to S9).

Then, the strobe latch timing adjustment step (steps S10 to S11) isperformed only for such a number of bits that the normal operation willnot be affected in response to a timing adjustment request, and thestrobe latch timing adjustment step for all bits of the data iscompleted through a plurality of timing adjustment requests (iterationsof steps S10 to S11).

Thereafter, the system latch timing adjustment step and the strobe latchtiming adjustment step are repeatedly performed in response to timingadjustment requests.

Note that the timing adjustment request may be issued constantlyimmediately after the system startup or at the system initialization,for example. Where the normal operation is required with synchronous orasynchronous timing, arbitration may be performed between the timingadjustment request and the normal operation request based on apredetermined order of priority so that the timing adjustment request isissued only when it has a higher priority.

SECOND EMBODIMENT

A data latch timing adjustment apparatus according to a secondembodiment of the present invention will now be described with referenceto the drawings.

FIG. 10 shows the apparatus of the second embodiment for adjusting thetiming for latching data in synchronism with a strobe signal.

In the present embodiment, a clock delay selection section 403 isprovided in place of the strobe delay selection section 103, and a clockdelay control section 410 is provided in place of the strobe delaycontrol section 110.

Thus, while the phase adjustment between the external strobe signal andthe system clock is performed by delaying the external strobe signal bythe strobe delay selection section 103 in the previous embodiment, thephase adjustment is performed by delaying the system clock by the clockdelay selection section 403 in the present embodiment.

More specifically, in the system latch timing adjustment step with theconfiguration of FIG. 1 described above, a delay control signal from thestrobe delay control section 110 is used to control the strobe delayselection section 103 so as to select the optimal delayed strobe fromamong a plurality of delayed strobe signals produced from a strobesignal. In contrast, in the system latch timing adjustment step of thepresent embodiment, a delay control signal from the clock delay controlsection 410 is used to control the clock delay selection section 403 soas to select the optimal delayed clock from among a plurality of delayedclock signals produced from the system clock s200. If there is apossibility that the strobe signal from the memory 100 might arrive atthe latch section earlier than the data, it is preferred that the strobesignal is delayed so that the delayed strobe signal will arrive laterthan the data. Moreover, the adjusted delayed system clock is suppliedonly to circuits subsequent to the section for reading out data from thememory 100, and if the clock for latching data needs to be switched fromthe system clock s200 to a delayed system clock, the data can be latchedwith a delayed system clock obtained by delaying the system clock s200by substantially the same delay amount as that introduced by the clockdelay selection section 403.

Otherwise, the configuration is similar to that shown in FIG. 1 and willnot be further described below.

FIG. 11 is a timing diagram of the system latch timing adjustment stepof the second embodiment.

In the system latch timing adjustment step, a delayed system clock s200′with a delay amount dey-s is produced from the system clock s200. Thestrobe latch section 106 produces check data in synchronism with thestrobe signal s100 a from the memory 100, and the check data is latchedwith the delayed system clock s200′. The check data latched with thedelayed system clock s200′ is compared with an expected value in theexpected value comparison section 108.

Thus, the present embodiment provides similar functions and effects tothose of the first embodiment. Moreover, in the present embodiment, thesystem clock s200 supplied to circuits subsequent to the section forreading out data from the memory 100 is delayed, whereby it is possibleto make such an adjustment that even accommodates delays occurring inthe memory 100 and the circuit board.

Although not shown in the drawings, it is understood that modificationsas shown in FIG. 7 and FIG. 8 may be made to the configuration of thepresent embodiment shown in FIG. 10.

First Variation of Second Embodiment

A first variation of the second embodiment will now be described withreference to FIG. 12.

In this variation, a change is made to the configuration of the clockdelay selection section 403 shown in FIG. 10.

Specifically, referring to FIG. 12, the clock delay selection section403 of this variation includes a fixed delay section 4030 and a variabledelay section 4031.

The fixed delay section 4030 receives the system clock s200, andsimultaneously produces a plurality of system clocks of different phasesfrom the system clock s200 to selectively output one of the systemclocks. Different phases of the system clock s200 can be easily producedby using a PLL circuit or a DLL circuit, for example.

The variable delay section 4031 includes a series of delay circuits40311, 40312 to 4031 n and a selection section 4031 a. The variabledelay section 4031 delays a system clock of a phase selected by thefixed delay section 4030 successively through the delay circuits 40311to 4031 n to produce a plurality of delayed system clocks with differentdelay amounts, and one of the outputs from the delay circuits 40311 to4031 n is selected by the selection section 4031 a.

Therefore, the delay amount for the delayed system clock can beincreased by significantly shifting the clock phase in advance at thefixed delay section 4030, thus realizing a fixed delay that is notaffected by variations in the ambient temperature or the voltage.Moreover, a fine adjustment of the delay amount done in the variabledelay section 4031 enables a timing adjustment with an even higherprecision.

1. A data latch timing adjustment method for receiving an externalstrobe signal and external data in synchronism with the external strobesignal, latching the external data with the external strobe signal andthen again latching the latched external data with a system clock, themethod comprising: a system latch timing adjustment step of producingcheck data in synchronism with the external strobe signal and performinga phase adjustment between the external strobe signal and the systemclock so that the check data is properly latched with the system clock;and a strobe latch timing adjustment step of performing a phaseadjustment between the external strobe signal and the external data sothat the external data is properly latched with the external strobesignal, the external strobe signal having a predetermined phaserelationship with the system clock as a result of the phase adjustmentperformed in the system latch timing adjustment step.
 2. The data latchtiming adjustment method of claim 1, wherein in the system latch timingadjustment step: a plurality of delayed strobe signals are produced bydelaying the external strobe signal with a plurality of delay amounts,and the check data is produced in synchronism with each delayed strobesignal; and one of the plurality of delayed strobe signals for which thecorresponding check data is properly latched with the system clock isselected as an optimal strobe signal.
 3. The data latch timingadjustment method of claim 1, wherein in the system latch timingadjustment step: the check data is produced in synchronism with theexternal strobe signal; a plurality of delayed system clocks areproduced by delaying the system clock with a plurality of delay amounts,and the check data is latched with each of the plurality of delayedsystem clocks; and one of the plurality of delayed system clocks withwhich the check data is properly latched is selected as an optimalsystem clock.
 4. The data latch timing adjustment method of claim 1,wherein in the strobe latch timing adjustment step: a plurality ofdelayed data are produced by delaying the external data with a pluralityof delay amounts; the plurality of delayed data are latched with theexternal strobe signal; and one of the plurality of delayed dataproperly latched is selected as optimal data.
 5. The data latch timingadjustment method of claim 1, wherein: the system latch timingadjustment step and the strobe latch timing adjustment step are eachperformed when a predetermined timing adjustment request is issued; anda time at which the predetermined timing adjustment request is issuedincludes at least one of at a system startup, at a system initializationand during a normal operation.
 6. The data latch timing adjustmentmethod of claim 2, wherein: the external strobe signal includes aplurality of bits; when the system latch timing adjustment step isrequested at a system startup or at a system initialization, a pluralityof delayed strobe signals are produced by delaying each bit of theexternal strobe signal with a plurality of delay amounts in the systemlatch timing adjustment step; and when the system latch timingadjustment step is requested during a normal operation, a plurality ofdelayed strobe signals are produced by delaying each of a predeterminednumber of bits of the external strobe signal with a plurality of delayamounts in the system latch timing adjustment step, the predeterminednumber of bits being less than the total number of bits of the externalstrobe signal.
 7. The data latch timing adjustment method of claim 4,wherein: the external data includes a plurality of bits; when the strobelatch timing adjustment step is requested at a system startup or at asystem initialization, a plurality of delayed data are produced bydelaying each bit of the external data with a plurality of delay amountsin the strobe latch timing adjustment step; and when the strobe latchtiming adjustment step is requested during a normal operation, aplurality of delayed data are produced by delaying each of apredetermined number of bits of the external data with a plurality ofdelay amounts in the strobe latch timing adjustment step, thepredetermined number of bits being less than the total number of bits ofthe external data.
 8. A data latch timing adjustment apparatus forreceiving an external strobe signal and external data in synchronismwith the external strobe signal, latching the external data with theexternal strobe signal and then again latching the latched external datawith a system clock, the apparatus comprising: a strobe delay selectionsection for delaying the external strobe signal with a plurality ofdelay amounts to produce a plurality of delayed strobe signals andselectively outputting one of the delayed strobe signals produced; adata delay selection section for delaying the external data with aplurality of delay amounts to produce a plurality of delayed data andselectively outputting one of the delayed data produced; a strobe latchsection for receiving the delayed data from the data delay selectionsection and the delayed strobe signal selected by the strobe delayselection section to produce check data in synchronism with the delayedstrobe signal and to latch the received delayed data or the producedcheck data in synchronism with the delayed strobe signal; a system latchsection for latching, with the system clock, the delayed data or thecheck data latched by the strobe latch section; a strobe delay controlsection for controlling the strobe delay selection section; and a datadelay control section for controlling the data delay selection section.9. The data latch timing adjustment apparatus of claim 8, furthercomprising: an expected value comparison section for comparing thedelayed data or the check data latched by the system latch section witha corresponding expected value to determine whether or not the delayeddata or the check data matches with the expected value; a strobe delaydetermination section for receiving a comparison result from theexpected value comparison section and determining one of the pluralityof delayed strobe signals produced in the strobe delay selection sectionto be an optimal strobe signal; and a data delay determination sectionfor receiving a comparison result from the expected value comparisonsection and determining one of the plurality of delayed data produced inthe data delay selection section to be optimal data.
 10. The data latchtiming adjustment apparatus of claim 9, wherein any data can be inputfrom outside as the check data.
 11. The data latch timing adjustmentapparatus of claim 8, wherein either one of the strobe delay controlsection and the data delay control section is provided and functionsboth as the strobe delay control section and as the data delay controlsection.
 12. The data latch timing adjustment apparatus of claim 8,wherein: the external strobe signal is an n-bit (n is an integer greaterthan or equal to 2) signal; and a number n of the strobe delay selectionsections are provided.
 13. The data latch timing adjustment apparatus ofclaim 9, wherein: the expected value comparison section is used commonlyin a strobe delay control operation and in a data delay controloperation; either one of the strobe delay determination section and thedata delay determination section is provided and functions both as thestrobe delay determination section and as the data delay determinationsection; and different data can be selected as the check data in thestrobe delay control operation and in the data delay control operation.14. The data latch timing adjustment apparatus of claim 8, wherein anydata can be input from outside as the check data.